package com.hoshiicloud.user.mapper.rbac;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hoshiicloud.rbac.entity.SysUsers;

import com.hoshiicloud.rbac.vo.SysUsersVO;
import com.hoshiicloud.user.entity.platform.PlatUsers;
import com.hoshiicloud.user.param.rbac.SysUsersQueryParam;
import org.springframework.stereotype.Repository;
import org.apache.ibatis.annotations.Param;

import javax.annotation.Resource;

/**
 * <p>
 * 用户 Mapper 接口
 * </p>
 *
 * @author Mr.Wu
 * @since 2019-04-18
 */
@Repository
public interface SysUsersMapper extends BaseMapper<SysUsers> {
    /**
     * SAAS系统分页查询所有员工列表
     * @param page
     * @param sysUsersQueryParam
     * @return
     */
    IPage<SysUsersVO> getAllEmployee(IPage<SysUsers> page, @Param("param") SysUsersQueryParam sysUsersQueryParam);

    /**
     * SAAS系统根据部门ID分页查询(包括子部门)员工列表
     * @param page
     * @param sysUsersQueryParam
     * @return
     */
    IPage<SysUsersVO> getEmployeeByDeptId(IPage<SysUsers> page, @Param("param") SysUsersQueryParam sysUsersQueryParam);

    /**
     * SAAS系统根据角色名称分页查询员工列表
     * @param page
     * @param sysUsersQueryParam
     * @return
     */
    IPage<SysUsersVO> getEmployeeByRoleName(IPage<SysUsers> page, @Param("param") SysUsersQueryParam sysUsersQueryParam);


}
